package config

// Config error codes

const (
	RESPONSE_SUCCESS = "0"
)

const REQUEST_ERROR = "1000"

const (
	REQUEST_DATAFORMATION_ERROR        = "1001"
	REQUEST_UNAUTHORIZATION_ERROR      = "1002"
	REQUEST_NOT_FOUND_ERROR            = "1003"
	REQUEST_USERNAME_OR_PASSWORD_ERROR = "1004"
	REQUEST_ORDER_TIME_INCORRECT       = "1005"
	REQUEST_TIME_HAVE_BEEN_ORDER       = "1006"
)

const RESPONSE_ERROR = "2000"

const (
	RESPONSE_SERVER_ERROR             = "2001"
	RESPONSE_DATABASE_ERROR           = "2002"
	RESPONSE_DATABASE_OPERATION_ERROR = "2003"
)

const UNKNOWN_ERROR = "3000"

// Config error message

var RESPONSE_MESSAGE map[string]string = map[string]string{
	"0":    "success",
	"1000": "request error",
	"1001": "request data formation error",
	"1002": "request authentication error",
	"1003": "request not fund error",
	"1004": "request username or password error",
	"1005": "request order time incorrect",
	"1006": "request time have been ordered",
	"2000": "response error",
	"2001": "response server error",
	"2002": "response database connect error",
	"2003": "response database operation error",
	"3000": "unknown error",
}
